<?php include './conn.php'; include './delete.php';?>
<html>
    <head>       
    </head>
    <body>
        <?php echo 'Show list of Students';?>
        <?php
            $show= 'select* from students;';
            $students= query($show);
            /*var_dump($students);*/
            mysql_query("DELETE FROM students WHERE id = '2'") or die(mysql_error()); 
        ?>
        <table border="1" cellspacing="0">
             <tr>
                <td>ID</td>
                <td>Name</td>
            </tr>
            <?php
                    foreach ($students as $student):
            ?>
                   
            <tr>
                <td>
                    <?php echo ($student['id']); ?>
                </td>
                 <td>
                    <?php echo ($student['name']); ?>
                </td>
                <td><label click="delete.send()">Xoa</label></td>
            </tr>
            <?php endforeach;?>
        </table>
    </body>
</html>
